#include "OSTask.h"

OSTask::OSTask()
{
}

void OSTask::getInput( QVector<QVector<int> >& in )
{
    in.resize(n);
    for (int i=0; i<n; i++)
        in[i].resize(m);
    in = input;
}

void OSTask::setInput( int n, int m, const QVector<QVector<int> >& in )
{
    this->n = n;
    this->m = m;
    input.resize( n );
    for (int i=0; i<n; i++)
        input[i].resize(m);
    input = in;
}

QDataStream & OSTask::operator<< (QDataStream & out)
{
    out << name << description <<
           algorithm << lastExecution;
    return out;
}

QDataStream & OSTask::operator>> (QDataStream & in)
{
    in >> name >> description >>
          algorithm >> lastExecution;
}
